<?php class Contact_m extends CI_Model {

    function __construct()
    {
        // Call the Model constructor
        parent::__construct();
          $this->load->database();
    }
     function get_destination()
    {
        $query=$this->db->get_where('contact', array('id' => 1));
        return $query->row_array();
    }
     function update_destination($data){
         return $this->db->update('contact',$data,array('id'=>1));
    }
     function get_code()
    {
        $query=$this->db->get_where('contact', array('id' => 2));
        return $query->row_array();
    }
     function update_code($data){
         return $this->db->update('contact',$data,array('id'=>2));
    }
}
?>
